/**
 * Created by jinglupeng on 2/12/16.
 */

var HelloMessage = module.exports = React.createClass({
    render: function () {
        console.log('render');
        return <div>
            <div onClick={this.handleClick}>Hello1 { this.props.name}</div>
        </div>;
    },
    handleClick: function () {
        this.setState({
            name: new Date().toString()
        });
        this.setProps({
            name: 'john_' + new Date().toString()
        });
        console.log(this);
    },
    statics: {
        changeName: function (name) {
            this.props.name = name;
        }
    }
});